<template>
  <view class="note">
    <view class="headLabel">
      <view class="span span01">名称</view>
      <view class="span">初稿</view>
      <view class="span">修改</view>
      <view class="span">降重</view>
      <view class="span" v-if="isShowDing">定稿</view>
    </view>
    <!-- status是0,1,2 进度条什么都不显示 -->
    <view class="bottom" v-if="orderInfo?.status == 0 || orderInfo?.status == 1 || orderInfo?.status == 2">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang"></view>
      </view>
      <view class="span span03">
        <view class="biankuang"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为3 只显示初稿 -->
    <view class="bottom" v-if="orderInfo?.status == 3">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为4 修改一 -->
    <view class="bottom" v-if="orderInfo?.status == 4">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang spanHover"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为5 只显示修改二 -->
    <view class="bottom" v-if="orderInfo?.status == 5">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang"></view>
        <view class="biankuang"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为6 只显示修改三 -->
    <view class="bottom" v-if="orderInfo?.status == 6">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为7 修改四 -->
    <view class="bottom" v-if="orderInfo?.status == 7">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span04">
        <view class="biankuang"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
    <!-- status 为8 定稿/降重 -->
    <view class="bottom" v-if="orderInfo?.status >= 8">
      <view class="span span01">
        <view class="text01">{{orderInfo?.order_no}}</view>
        <view class="text02">{{orderInfo?.name}}</view>
      </view>
      <view class="span span02">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span03">
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span04">
        <view class="biankuang spanHover"></view>
      </view>
      <view class="span span05" v-if="isShowDing">
        <view class="biankuang"></view>
      </view>
    </view>
  </view>
</template>

<script setup>
  const props = defineProps({
    isShowDing: {
      type: Boolean,
      default: () => false
    },
    userInfo: {
      type: Object,
      default: () => ({})
    },
    orderInfo: {
      type: Object,
      default: () => ({})
    }
  });
</script>

<style lang="scss" scoped>
  .note {
    width: 650rpx;
    font-family: PingFang SC;
    font-weight: 400;
    font-size: 24rpx;
    text-align: center;
    color: rgba(35, 35, 35, 0.52);
    margin-bottom: 20rpx;
    .headLabel{
      width: 100%;
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;
      border-bottom: 2rpx dashed rgba(146, 146, 146, 1);
      padding-bottom: 20rpx;
      .span{
        font-family: HarmonyOS Sans SC;
        font-weight: 400;
        font-size: 24rpx;
        text-align: center;
        color: rgba(122, 122, 122, 1);
      }
      .span:nth-child(1){
        width: 40%;
        // background: blue;
      }
      .span:nth-child(2){
        width: 10%;
        // background: red;
      }
      .span:nth-child(3){
        width: 30%;
        // background: yellow;
      }
      .span:nth-child(4){
        width: 10%;
        // background: black;
      }
      .span:nth-child(5){
        width: 10%;
        margin-right: 1%;
        // background: bisque;
      }
    }
    .bottom{
      width: 650rpx;
      height: 84rpx;
      border-radius: 6rpx;
      background: rgba(209, 243, 241, 1);
      display: flex;
      flex-direction: row;
      align-items: center;
      justify-content: space-between;
      margin-top: 20rpx;
      margin-bottom: 20rpx;
      .span{
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        .text01{
          font-family: HarmonyOS Sans SC;
          font-weight: 400;
          font-size: 28rpx;
          text-align: center;
          color: rgba(60, 60, 60, 1);
        }
        .text02{
          font-family: HarmonyOS Sans SC;
          font-weight: 400;
          text-align: center;
          color: rgba(60, 60, 60, 1);
          font-size: 20rpx;
          margin-left: 10rpx;
        }
        .biankuang{
          width: 28rpx;
          height: 26rpx;
          border-radius: 6rpx;
          border: 2rpx solid rgba(11, 105, 218, 1);
          display: inline-block;
          margin-right: 10rpx;
          flex-shrink: 0;
        }
        .spanHover{
          background: rgba(28, 246, 21, 1);
        }
        .biankuang:nth-last-child(1){
          margin-right: 0;
        }
      }
      .span01{
        width: 39%;
        flex-direction: column;
        // background: blue;
      }
      .span02{
        width: 10%;
        flex-direction: row;
        // background: red;
      }
      .span03{
        width: 30%;
        flex-direction: row;
        // background: yellow;
      }
      .span04{
        width: 10%;
        flex-direction: row;
        // background: black;
      }
      .span05{
        width: 10%;
        flex-direction: row;
        margin-right: 1%;
        // background: bisque;
      }
  
    }
  }
</style>